
$(function(){

    $('#fullpage').fullpage({
        afterLoad: function (link, index) {
            $('.section').removeClass('curr');
            setTimeout(function () {
                $('.section').eq(index - 1).addClass('curr');
            }, 100);
        }
    });




   $('.audio').toggle(
        function(){
            $('#media')[0].play();
        },
       function(){
           $('#media')[0].pause();
       }
   );

    $('.audio').click(function(){
        $(this).toggleClass('amon');
    });

});
window.addEventListener("onorientationchange" in window ? "orientationchange" : "resize", hengshuping, false);
function hengshuping() {
    if (window.orientation == 90 || window.orientation == -90) {
        alert('请在竖屏下浏览');
    } else {
        //竖屏
    }
}